
<?php include_once(dirname(__FILE__) . '/../general/head.php'); ?>

<!-- header -->
<?php include_once(dirname(__FILE__) . '/../general/header.php'); ?>

<?php include_once('left.php'); ?>


<div id="page-wrapper">

    <div class="row">
        <div class="col-lg-12">
            <h1 class="page-header">Đợt đánh giá</h1>
        </div>
        <!-- /.col-lg-12 -->
    </div>
    <!-- /.row -->
    <div class="row">
        <div class="col-lg-12">
            <div class="panel panel-default">
                <div class="panel-heading">
                    Danh sách
                </div>
                <!-- /.panel-heading -->
                <div class="panel-body">
                    <?php if ($evaluations == false) { ?>
                        Hiện tại không có đợt đánh giá nào!
                        <br>
                    <?php } else { ?>
                        <div class="table-responsive">
                            <table class="table table-striped table-bordered table-hover sb-table">
                                <thead>
                                    <tr>
                                        <th>Id</th>
                                        <th>Tên</th>
                                        <th>Ngày tạo</th>
                                        <th>&nbsp;</th>
                                    </tr>
                                </thead>
                                <tbody>


                                    <?php
                                    foreach ($evaluations as $eachE) {
                                        ?>
                                        <tr>
                                            <td><?php echo $eachE->id; ?></td>
                                            <td><?php echo $eachE->name; ?></td>
                                            <td><?php echo $eachE->created_day; ?></td>
                                            <td>
                                                <a href="<?php echo site_url(get_folder($loggedUser['title']).'/evaluations/edit/' . $eachE->id); ?>">
                                                    <img src="<?php echo base_url(); ?>images/edit.png" title="Edit">
                                                </a>
<!--                                                <a href="javascript: if(confirm('Bạn có chắc là muốn xóa không??')){ window.location='<?php echo site_url(get_folder($loggedUser['title']).'/evaluations/delete/' . $eachE->id); ?>'; }">
                                                    <img src="<?php echo base_url(); ?>images/cross.png" title="Delete">
                                                </a>-->
                                            </td>
                                        </tr>

                                    <?php } ?>

                                </tbody>
                            </table>

                        </div>
                    <?php } ?>
                    <br>
<!--                    <a href="<?php echo site_url(get_folder($loggedUser['title']).'/evaluations/add'); ?>"> <img src="<?php echo base_url(); ?>images/plus.png" title="Thêm đợt đánh giá"> Thêm đợt đánh giá</a>
                    <br>-->

                </div>
                <!-- /.panel-body -->
            </div>
            <!-- /.panel -->



        </div>
        <!-- /.col-lg-12 -->
    </div>


</div>
<!-- /#page-wrapper -->

<?php include_once(dirname(__FILE__) . '/../general/footer.php'); ?>